#version 150

#define UNIT_SIZE (16.0)
#define OVERLAY_ALPHA (254)
#define POTION_ALPHA (253)
//editable
#define OVERLAY_SIZE (80.0)
#define IS_GLINT (0)

bool check_rgb(vec3 textureRGB, vec3 targetRGB) {
	bool R = (abs(textureRGB.r - targetRGB.r)<0.1);
	bool G = (abs(textureRGB.g - targetRGB.g)<0.1);
	bool B = (abs(textureRGB.b - targetRGB.b)<0.1);
	return (R && G && B);
}

bool check_alpha(float textureAlpha, float targetAlpha) {
	/*
	alpha 253: potion overlayer
	alpha 254: potion textures
	*/
	float targetLess = targetAlpha - 0.01;
	float targetMore = targetAlpha + 0.01;
	return (textureAlpha > targetLess && textureAlpha < targetMore);
	
}